import request from "@/request/request"
// 请求精品数据
export const JinPingAPI = () => request.get("/products/recommend")
// 请求热门数据
export const ReMenAPI = () => request.get("/products/hot")
// 请求详情页数据
export const GoodsDetailAPI = (id) => request.get(`/products/${id}`)
//获取用户信息
export const UserProfilesAPI = () => request.get("/shop/userProfiles")
export const GoodsSeachAPI = (params) => request.get(`/products`, { params })
export const shopCartAPI = () => request.get(`/shop/carts`)
//验证手机验证码
import qs from 'qs'
// 获取验证码
export const SendSMSAPI = (params) => request.post("/sendSMS", qs.stringify(params))
// 登录请求
export const PhoneReginAPI = (params) =>
    request.post("/phoneRegin", qs.stringify(params));
//微信扫码登录请求
export const WeixinLoginApi = (params) =>
    request.post("/wechatUsers/PCLogin", qs.stringify(params));
export const BndingApi = (params) =>
    request.post("/wechatUsers/binding", qs.stringify(params));
export const AddToCartAPI = (params) =>
    request.post("/shop/carts/add", qs.stringify(params));

export const delShopCartAPI = () => request.get(`/shop/carts`)